<?php
// *** Tangra (Application Framework and Tools for PHP)
// $Id$
//

require_once(TANGRA_MAIN_DIR.'web_site/web_site_config_loader_file.class.php');


class Web_Site_Vanilla_Config_Loader_File extends Web_Site_Config_Loader_File {
	public function load_site_config(Web_Site_Config $WSC, $params) {
		parent::load_site_config($WSC, $params);

		if ($this->ms_fl->get_conf_value('MS_LOG_EXCEPTIONS')) {
			$WSC->set_log_exceptions($this->ms_fl->get_conf_value('MS_LOG_EXCEPTIONS'));
		}

		if ($this->ms_fl->get_conf_value('MS_EXCEPTIONS_LOG_FILE')) {
			$WSC->set_exceptions_log_file($this->ms_fl->get_conf_value('MS_EXCEPTIONS_LOG_FILE'));
		}

		if ($this->ms_fl->get_conf_value('MS_SAVE_CONTEXT_ON_EXCEPTION')) {
			$WSC->set_save_context_on_exception($this->ms_fl->get_conf_value('MS_SAVE_CONTEXT_ON_EXCEPTION'));
		}

		if ($this->ss_fl->get_conf_value('SS_DEFAULT_LANGUAGE')) {
			$WSC->set_default_language($this->ss_fl->get_conf_value('SS_DEFAULT_LANGUAGE'));
		}

		if ($this->ss_fl->get_conf_value('SS_AVAILABLE_LANGUAGES')) {
			$WSC->set_available_languages($this->ss_fl->get_conf_value('SS_AVAILABLE_LANGUAGES'));
		}


	}
}

